package com.lxyk.domain;

import com.lxyk.utils.StrDateUtils;
import com.lxyk.utils.StringToDateConverter;
import lombok.AllArgsConstructor;
import lombok.Data;

import java.util.Date;

//班级表
public class Classes {
    private Integer id;
    private String className;
    private Date openTime;
    private Date closeTime;
    private Integer statusClass;//0:在读  1:已结课
    private String speed;
    private Integer classSize;
    private Integer effeNumber;
    private Integer outNumber;

    public Classes() {
    }

    public Classes(Integer id, String className, Date openTime, Date closeTime, Integer statusClass, String speed, Integer classSize, Integer effeNumber) {
        this.id = id;
        this.className = className;
        this.openTime = openTime;
        this.closeTime = closeTime;
        this.statusClass = statusClass;
        this.speed = speed;
        this.classSize = classSize;
        this.effeNumber = effeNumber;
    }

    public Classes(Integer id, String className, Date openTime, Date closeTime, Integer statusClass, String speed, Integer classSize, Integer effeNumber, Integer outNumber) {
        this.id = id;
        this.className = className;
        this.openTime = openTime;
        this.closeTime = closeTime;
        this.statusClass = statusClass;
        this.speed = speed;
        this.classSize = classSize;
        this.effeNumber = effeNumber;
        this.outNumber = outNumber;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getClassName() {
        return className;
    }

    public void setClassName(String className) {
        this.className = className;
    }

    public Date getOpenTime() {
        return openTime;
    }

    public void setOpenTime(Date openTime) {
        this.openTime = openTime;
    }

    public Date getCloseTime() {
        return closeTime;
    }

    public void setCloseTime(Date closeTime) {
        this.closeTime = closeTime;
    }

    public Integer getStatusClass() {
        return statusClass;
    }

    public void setStatusClass(Integer statusClass) {
        this.statusClass = statusClass;
    }

    public String getSpeed() {
        return speed;
    }

    public void setSpeed(String speed) {
        this.speed = speed;
    }

    public Integer getClassSize() {
        return classSize;
    }

    public void setClassSize(Integer classSize) {
        this.classSize = classSize;
    }

    public Integer getEffeNumber() {
        return effeNumber;
    }

    public void setEffeNumber(Integer effeNumber) {
        this.effeNumber = effeNumber;
    }

    public Integer getOutNumber() {
        return outNumber;
    }

    public void setOutNumber(Integer outNumber) {
        this.outNumber = outNumber;
    }

    public String getOpenTimeStr() {
        return StrDateUtils.dateToStr(openTime);
    }

    public String getCloseTimeStr() {
        return StrDateUtils.dateToStr(closeTime);
    }

    @Override
    public String toString() {
        return "Classes{" +
                "id=" + id +
                ", className='" + className + '\'' +
                ", openTime=" + openTime +
                ", closeTime=" + closeTime +
                ", statusClass=" + statusClass +
                ", speed='" + speed + '\'' +
                ", classSize=" + classSize +
                ", effeNumber=" + effeNumber +
                ", outNumber=" + outNumber +
                '}';
    }
}
